package com.dabai.videobrowser.adapter;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.viewholder.BaseViewHolder;
import com.dabai.videobrowser.R;
import com.dabai.videobrowser.bean.VideoListModel;

import java.util.List;

/**
 * Description : Other
 *
 * @author BAI
 */
public class VideoListAdapter extends BaseQuickAdapter<VideoListModel, BaseViewHolder> {


    public VideoListAdapter(@Nullable List<VideoListModel> data) {
        super(R.layout.item_drawer_main_end, data);
    }

    @Override
    protected void convert(@NonNull BaseViewHolder baseViewHolder, VideoListModel videoListModel) {
        baseViewHolder.setText(R.id.textView1,  videoListModel.getId()+". "+videoListModel.getName());
        baseViewHolder.setText(R.id.textView2,"大小:"+ videoListModel.getSize());
        baseViewHolder.setText(R.id.textView3, "时长:"+videoListModel.getTime());
    }
}
